import { Component, OnInit } from '@angular/core';

import { UserCollection } from './shared/user-collection.model';
import { UserCollectionService } from './shared/user-collection.service';

@Component({
	selector: 'user-collection',
	templateUrl: 'user-collection.component.html',
	providers: [UserCollectionService]
})

export class UserCollectionComponent implements OnInit {
	userCollection: UserCollection[] = [];

	constructor(private userCollectionService: UserCollectionService) { }

	ngOnInit() {
		this.userCollectionService.getList().subscribe((res) => {
			this.userCollection = res;
		});
	}
}